package com.ruoyi.workflow.domain;

import com.ruoyi.workflow.myenum.MessageType;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.Date;

/**
 * @Author zhouzhixiong
 * @Date 2024/3/11 22:13
 */

@Data
public class Message {
    @ApiModelProperty(value = "主键ID")
    private Integer id;

    @ApiModelProperty(value = "用户ID")
    private String userId;

    @ApiModelProperty(value = "消息类型")
    private MessageType messageType;

    @ApiModelProperty(value = "消息内容")
    private String messageContent;

    @ApiModelProperty(value = "详情链接")
    private String detailUrl;

    @ApiModelProperty(value = "创建时间")
    private Date createTime;

    // 默认无参构造函数
    public Message() {
    }

    /**
     * @param urseId 用户ID
     * @param messageType 消息类型
     * @param messageContent 消息内容
     * @param detailUrl 详情跳转路径
     */
    public Message(String urseId,MessageType messageType, String messageContent, String detailUrl) {
        this.userId = urseId;
        this.messageType = messageType;
        this.messageContent = messageContent;
        this.detailUrl = detailUrl;
    }
}
